﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Web.UI;

namespace GrayParrot.Web.Controls
{
    /// <summary>
    /// Column class definition...
    /// </summary>
    [TypeConverter(typeof(ExpandableObjectConverter))]
    public abstract class Column
    {
        public string Name { get; set; }
        public string Header { get; set; }
        public bool Visible { get; set; }
        public bool Required { get; set; }
        public string DefaultContent { get; set; }

        public bool Editable { get; set; }
        public bool AllowNull { get; set; }

        internal ColumnTypes Type { get; set; }

        public bool ReadOnly { get; set; }
        public string Width { get; set; }

        //public bool UserDropDownFilter { get; set; }
        //public string FilterBoxWidth { get; set; }
        //public bool ShowInEdit { get; set; }
        //public bool Searchable { get; set; }
        //public string DropDownSource { get; set; }
        //public string DropDownSourceParameters { get; set; }
        //public bool Key { get; set; }

        public Column()
        {
            Visible = true;
            Required = false;
            Editable = false;
            DefaultContent = string.Empty;
            AllowNull = true;

            //Searchable = false;
            //ShowInEdit = true;
        }
    }
}
